package com.jinmdz.fmis.dao.admin.dao;

import com.jinmdz.fmis.dao.admin.model.businesssystem.BusinessSystemListItem;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.ArrayList;

/**
 * 业务系统Dao
 *
 * @author LiCongLu
 * @date 2020-03-18 11:10
 */
public interface BusinessSystemDao {

    /**
     * 加载业务系统列表
     *
     * @param
     * @return
     * @author LiCongLu
     * @date 2020-03-18 11:11
     */
    @Select(" select id,system_name,system_code,disable_state,sort,remark,version " +
            " from business_system where deleted = 0 ")
    ArrayList<BusinessSystemListItem> listBusinessSystemList();

    /**
     * 按照主键查询业务系统
     *
     * @param id 主键
     * @return
     * @author LiCongLu
     * @date 2020-03-18 13:12
     */
    @Select(" select id,system_name,system_code,disable_state,sort,remark,version " +
            " from business_system where id = #{id} and deleted = 0 ")
    BusinessSystemListItem getBusinessSystemListById(@Param("id") Integer id);
}
